package com.sky.mapper.admin;

import com.sky.pojo.SetmealDish;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface SetmealDishMapper {
    /**
     * 根据菜品id查询数量
     * @param ids
     * @return
     */
    Integer selectCountByDishIds(@Param("ids") List<Long> ids);

    void inserBatch(List<SetmealDish> setmealDishes);

    void deleteBySetmealId(List<Long> ids);

    @Select("select * from setmeal_dish where setmeal_id = #{setmealId}")
    List<SetmealDish> getSetmealDishById(Long setmealId);
}
